Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preload 3DEN and Zeus item lists #1084

Merged
merged 16 commits into from
Mar 2, 2019
Merged

Preload 3DEN and Zeus item lists #1084

merged 16 commits into from
Mar 2, 2019

Conversation

commy2
Copy link
Contributor

@commy2 commy2 commented Feb 28, 2019

When merged this pull request will:

  • Adds cba_ui_fnc_preload3den to generate the item list used as mission attribute in the editor.
  • Adds cba_ui_fnc_preloadCurator to generate the complete item list for the RscAttributeInventory display used on weapon crates in Zeus.
  • Adds test_preload.sqf"; unit test to check validity of the preloaded item lists (compares them to the lists you get with vanilla or w/e other modset)

Note that the test requires a previewed mission in 3den for the curator part.

The functions to generate these lists are taken from vanilla, but optimized / ace-ified.

@commy2 commy2 added the Feature label Feb 28, 2019
@commy2 commy2 added this to the 3.10 milestone Feb 28, 2019
@commy2 commy2 changed the title Preload zeus Preload 3DEN and Zeus item lists Feb 28, 2019
@commy2
Copy link
Contributor Author

commy2 commented Feb 28, 2019

execVM "\x\cba\addons\ui\test_preload.sqf";
17:59:18 [CBA] (ui) Test OK: (cba_ui_fnc_preload3DEN is defined) x\cba\addons\ui\test_preload.sqf:7
17:59:18 [CBA] (ui) Test OK: (_vanilla isEqualTo _cba) x\cba\addons\ui\test_preload.sqf:17
17:59:18 [CBA] (ui) Test OK: (cba_ui_fnc_preloadCurator is defined) x\cba\addons\ui\test_preload.sqf:20
17:59:19 [CBA] (ui) Test OK: (_vanilla isEqualTo _cba) x\cba\addons\ui\test_preload.sqf:43

@dedmen
Copy link
Contributor

dedmen commented Feb 28, 2019

why two seperate functions? seems like they are mostly duplicate code?

@commy2
Copy link
Contributor Author

commy2 commented Feb 28, 2019

BI copy pasted one from the other obviously, but the loops around it are different, and they pushBack a different array format / element orders into the respective lists.
I think this is better as two functions.

@commy2 commy2 modified the milestones: 3.10, 3.10.1 Feb 28, 2019
@commy2 commy2 modified the milestones: 3.10.1, 3.10 Mar 2, 2019
@commy2 commy2 merged commit 7bdde2e into master Mar 2, 2019
@commy2 commy2 deleted the preloadZeus branch March 2, 2019 18:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants